package com.visionet.school.app.web.repository.wechat;

import com.visionet.school.app.web.entity.wechat.MemberLogin;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.data.jpa.repository.Query;
import org.springframework.data.repository.PagingAndSortingRepository;
import org.springframework.stereotype.Repository;

/**
 * Created by hxpeng on 2017/3/23.
 */

@Repository
public interface MemberLoginRepository extends PagingAndSortingRepository<MemberLogin,String>,JpaSpecificationExecutor<MemberLogin> {


    @Query("from MemberLogin as ml where ml.isDeleted='0' and ml.openId = ?1 ")
    public MemberLogin findoOneByOpenId(String openId);
}
